package e.odbo.data.dao.interceptor;

import e.odbo.data.bean.IKeyed;
import e.odbo.data.bean.I_BaseBean;
import e.odbo.data.dao.I_DAOInterceptor;

public abstract class AbstractDAOInterceptor<T extends I_BaseBean> implements I_DAOInterceptor<T> {
    @Override
    public boolean beforeInsert(T obj) {
        return true;
    }

    @Override
    public T afterInsert(T obj) {
        return obj;
    }

    @Override
    public boolean beforeUpdate(T obj) {
        return true;
    }

    @Override
    public T afterUpdate(T obj) {
        return obj;
    }

    @Override
    public boolean beforeDelete(IKeyed obj) {
        return true;
    }

    @Override
    public void afterDelete(IKeyed obj) {
    }
}
